<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head th:include="htmlHead :: common_header"/>
<body>
<a class="btn btn-primary radius"
   onclick="dataSyn()" href="javascript:;"><i class="Hui-iconfont">&#xe600;</i> 同步数据</a>
<div id="modal-demo" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content radius">
            <div class="modal-header">
                <h3 class="modal-title">提示</h3>
                <a class="close" data-dismiss="modal" aria-hidden="true" href="javascript:void(0);">×</a>
            </div>
            <div class="modal-body">
                <p>同步数据成功！</p>
            </div>
            <div class="modal-footer">
                <button class="btn btn-primary">确定</button>
                <button class="btn" data-dismiss="modal" aria-hidden="true">关闭</button>
            </div>
        </div>
    </div>
</div>
<script th:inline="javascript">
    function dataSyn(){
        $.ajax({
            url: "/dataSyn/syn",
            success: function(){
                $("#modal-demo").modal("show");
            }
        });
        //$.Huimodalalert('我是消息框，2秒后我自动滚蛋！',200000)
    }
</script>
</body>
</html>